﻿<Window x:Class="SenenFernandez.DisplayManager.MainView"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:ViewModel="clr-namespace:SenenFernandez.DisplayManager.ViewModel"
        WindowStartupLocation="CenterScreen"
        WindowStyle="ToolWindow"
        SizeToContent="WidthAndHeight"
        MinWidth="250" MinHeight="100"
        Title="{Binding Title}">
    <Window.DataContext>
        <ViewModel:MainViewModel />
    </Window.DataContext>
    <Window.Resources>
        <Style x:Key="AlertText" TargetType="Label">
            <Setter Property="Foreground" Value="Red" />
            <Setter Property="FontWeight" Value="Bold" />
        </Style>
    </Window.Resources>
    <DockPanel>
        <StackPanel Orientation="Horizontal" DockPanel.Dock="Top">
            <Label Content="Monitor:" />
            <ComboBox ItemsSource="{Binding Monitors}" SelectedItem="{Binding SelectedMonitor}">
                <ComboBox.ItemTemplate>
                    <DataTemplate>
                        <TextBlock Text="{Binding Name}" />
                    </DataTemplate>
                </ComboBox.ItemTemplate>
            </ComboBox>
        </StackPanel>
        <DockPanel>
            <StackPanel Orientation="Horizontal" DockPanel.Dock="Top">
                <Label Content="WorkingArea:" />
                <Label Content="{Binding SelectedMonitor.WorkingArea}" />
            </StackPanel>
            <Label Style="{StaticResource AlertText}" DockPanel.Dock="Bottom" Content="{Binding AlertText}" />
        </DockPanel>
    </DockPanel>
</Window>
